import { _decorator, Component, native, Node } from 'cc';
const { ccclass, property } = _decorator;

@ccclass('Game')
export class Game extends Component {
    start() {

    }

    update(deltaTime: number) {
        
    }

    syncClick() {
        console.log("cocos demo start syncClick");
        let ret = native.reflection.callStaticMethod("entry/src/main/ets/util/InteractionDemo", "entry/syncFunction", "param", true);
        console.log(`cocos demo end syncClick, ret is ${ret}`);
    }

    asyncClick() {
        console.log("cocos demo start asyncClick");
        let ret = native.reflection.callStaticMethod("entry/src/main/ets/util/InteractionDemo", "entry/asyncFunction", "param", false);
        console.log(`cocos demo end asyncClick, ret is ${ret}`);
    }
}


